﻿@using Citi.GocAttributes.WebUI.Models
@model IEnumerable<Citi.GocAttributes.WebUI.Models.ImportHistoryModel>
@{
    ViewBag.Title = "Import History";
}
@section Menu
{
    @Html.Partial("~/Views/Menu/Import.cshtml")
}
<h2>
    Import History</h2>
<table class="table table-bordered table-striped tablesorter-blue">
    <thead>
        <tr>
            <th>
                File Name
            </th>
            <th>
                Upload Date
            </th>
            <th>
                Status
            </th>
            <th>
            </th>
        </tr>
    </thead>
    <tbody>
        @foreach (var item in Model)
        {
            <tr>
                <td>
                    @Html.DisplayFor(modelItem => item.FileName)
                </td>
                <td>
                    @Html.DisplayFor(modelItem => item.UploadDate)
                </td>
                <td>
                    @Html.DisplayFor(modelItem => item.Status)
                </td>
                <td>
                    @if (item.ImportErrors.Any())
                    {
                        @Html.ActionLink("Details", "Details", new { id = item.Id }, new { @class = "icon-eye-open" })
                    }
                </td>
            </tr>
        }
    </tbody>
</table>
@Html.Partial("~/Views/PartialView/Pager.cshtml", new PagerModel { ColumnStartIndex = 1, ColumnStartOrder = PagerModel.Order.Descending })
